#pragma once

#include "Synonym.h"
#include "QueryType.h"

#include <cstddef>

/* ------------------------------------------------------------------------------------------
* A superclass that allows query types to be inherited from.
*
* Query types (currently) consists of:
*	Follows
*	Follows*
*	Modifies
*	Parent
*	Parent*
*	Uses
*	Pattern
* all of which inherits from this Query class.
* ------------------------------------------------------------------------------------------- */

class Query {
protected:
	Synonym *inputOne; /**< The first synonym of the query */
	Synonym *inputTwo; /**< The second synonym of the query */
	Synonym *inputThree; /**< The third synonym of the query */
	QueryType queryType; /**< The query type of the query */

public:
	/** Constructor
	 * Constructs a query that contains 2 synonyms
	 * @param arg1 first synonym
	 * @param arg2 second synonym
	 */
	Query(Synonym *arg1, Synonym *arg2);

	/** Constructor
	 * Constructs a query that contains 2 synonyms
	 * @param arg1 first synonym
	 * @param arg2 second synonym
	 * @param arg3 third synonym
	 */
	Query(Synonym *arg1, Synonym *arg2, Synonym *arg3);

	/** 
	 * Gets the query type of the query
	 * @return the query type
	 */
	virtual QueryType getQueryType();

	/** 
	 * Gets the first synonym or argument of the query
	 * @return the first synonym or argument
	 */
	virtual Synonym *getFirstArgument();

	/** 
	 * Gets the second synonym or argument of the query
	 * @return the second synonym or argument
	 */
	virtual Synonym *getSecondArgument();

	/** 
	 * Gets the third synonym or argument of the query
	 * @return the third synonym or argument
	 */
	virtual Synonym *getThirdArgument();

	/** Destructor
	 * Cleans up the query
	 */
	~Query();
};